/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package Model;

import java.text.NumberFormat;

public class LineMobile {
    private Mobile mb;
    private int quantity;

    public LineMobile() {
    }

    public Mobile getMb() {
        return mb;
    }

    public void setMb(Mobile mb) {
        this.mb = mb;
    }

    public int getQuantity() {
        return quantity;
    }

    public void setQuantity(int quantity) {
        this.quantity = quantity;
    }

    public  double getTotal(){
        double total =mb.getGiaSauKhiGiam()*this.quantity;
        return total;
    }

    public String getTotalCurrencyFormat(){
        NumberFormat currency = NumberFormat.getInstance();
        return currency.format(this.getTotal());
    }

}
